<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org"
      xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<meta charset="utf-8">
<head th:include="common :: header"></head>
<body>
<div>
    <div th:include="common :: navigation"></div>
    <div class="container">
        <div class="col-lg-3" style="height: 100%">
            <div class="panel panel-default">
                <div class="panel-heading categoryh"><font size="5" style="color: #0e9aef"><strong>栏目列表</strong></font>
                </div>
                <div class="panel-body">
                    <li th:each="cate : ${list}">
                        <a th:utext="${cate.name}" th:href="${'/front/categoryById/'+cate.id +'/' +id}"></a>
                    </li>
                </div>
            </div>
            <div class="panel panel-default">
                <div class="panel-heading categoryh"><font size="5" style="color: #0e9aef"><strong>推荐阅读</strong></font>
                </div>
                <div class="panel-body">

                </div>
            </div>
        </div>
        <div class="col-lg-9">
            <div class="row">
                <div class="col-lg-6" style="height:300px;float: left" th:each="cate : ${list}">
                    <div class="panel panel-default">
                        <div class="panel-heading categoryh">
                            <span th:text="${cate.name}"></span><a onclick='' style='float: right'>更多>></a>
                        </div>
                        <div class="panel-body">
                            <ul class="list-group">
                                <div th:each="article : ${articleList}">
                                    <li class="list-group-item"
                                        th:if="(${cate.id} == ${article.categoryId})">
                                        <a th:href="@{/front/articleById(id=${article.id})}">
                                            <span th:text="${article.title}"></span>
                                        </a>
                                        <span th:text="${#dates.format(article.createTime, 'yyyy-MM-dd HH:mm:ss')}"></span>
                                    </li>
                                </div>
                            </ul>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>

</div>
<div th:include="common :: footer"></div>

</body>
</html>